export default {
  namespaced: true,
  state: () => ({
    // 用户信息  
    haslogin: false,  
    email: '2281250383@qq.com',
    name: '张三',
    uid: 3,
    major: null,
    age: null,
    sex: null,
    birth: null,
    score: null,
    superadmin: false,
  }),
  actions: {
  },
  getters: {
  },
  mutations: {
    LoginOut: function (state) {
      console.log("loginout in vuex");
      state.haslogin = false;
    },
    LoginIn: function (state, param) {
      console.log('loginin in vuex');
      state.haslogin = true;
      state.name = param[0];
      state.email = param[1];
      state.uid = param[2];
      console.log(state.haslogin, state.name, state.uid);
    }
  },
}
